//
// Created by augtons on 2022/1/20.
//

#ifndef WINDSWING_MOTO_CTRL_H
#define WINDSWING_MOTO_CTRL_H

#include "driver/mcpwm.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"

#define MOTO1A  (22)
#define MOTO1B  (23)

#define MOTO2A  (15)
#define MOTO2B  (4)

#define MOTO3A  (13)
#define MOTO3B  (12)

#define MOTO4A  (14)
#define MOTO4B  (27)

void init_mcp();
void moto_stop(int motoIndex);
void moto_backward(int motoIndex, float duty);
void moto_forward(int motoIndex, float duty);

#endif //WINDSWING_MOTO_CTRL_H
